<template>
  <v-layout>
    <v-sider :fixed="true" toggle-mode="slide" :style="{'margin-left':(hideSider?'-180px':0),'margin-top':'50px'}">
      <ul class="vui-component-nav">
        <li v-for="router in routers">
          <router-link :to="router.path">{{router.label}}</router-link>
        </li>
      </ul>
    </v-sider>
    <v-scrollbar theme="dark" class="vui-content">
        <keep-alive>
          <router-view></router-view>
        </keep-alive>
    </v-scrollbar>
  </v-layout>
</template>

<script type="text/">
import { ComponentRouter } from '../../app.vui.router';
import { vLayout, vSider, vScrollbar } from '../../../vui/components/api';
import API from '../api';
export default {
  name: 'Components',
  props: {
    hideSider: {
      type: Boolean,
      default:false
    }
  },
  data () {
    return {
      msg: '我就是组件模块',
      routers: ComponentRouter.slice(1),
    }
  },

  created:function(){
  },
  methods: {
  },
  components: {
    vLayout,
    vSider,
    vScrollbar
  }
}
</script>